#ifndef SQLListExpr_HEADER_H
#define SQLListExpr_HEADER_H

#include <list>
#include "../SQLExpr.h"
#include "../SQLExprImpl.h"

class SQLASTVisitor;

class SQLListExpr : virtual public SQLExprImpl
{

private:
  SQLExpr_list_ptr  items;

public:
  SQLListExpr();
  SQLListExpr(SQLExpr_list_ptr  items);
  SHAREDOBJECT(SQLListExpr);
  virtual ~SQLListExpr();
  SQLExpr_list_ptr  getItems();
  void addItem(SQLExpr_ptr item);

  int hashCode();
  bool equals(Object_ptr obj);
  // SQLListExpr* clone();
  virtual SQLObject_ptr clone();
  SQLObject_list_ptr  getChildren()
  {
    SQLObject_list_ptr  newClass = SQLObject_list_ptr ();
    for (auto it : *this->items)
    {
      newClass->push_back(std::dynamic_pointer_cast<SQLObject>(it));
    }
    return newClass;

    // return this->items;
  }
  BOOL_ptr replace(SQLExpr_ptr expr, SQLExpr_ptr target);

  bool containsAttribute(string_ptr name){};
  void addBeforeComment(string_list_ptr  comments){};
  string_list_ptr  getAfterCommentsDirect(){};
  string_list_ptr  getBeforeCommentsDirect(){};
  void addAfterComment(string_ptr  comment){};
  void addAfterComment(string_list_ptr  comments){};
  bool hasBeforeComment(){};
  bool hasAfterComment(){};

protected:
  void accept0(SQLASTVisitor_ptr visitor) override;
};
// typedef boost::shared_ptr<SQLListExpr> SQLListExpr_ptr;

#endif
